﻿namespace EyFramework.Library
{
    /// <summary>
    /// lookupEdit 的列配置项
    /// </summary>
    public class SelGridColumn
    {
        private string _colCode = string.Empty;

        private string _colName = string.Empty;

        private bool _colShow = true;

        private int _colWidth = 0;

        /// <summary>
        /// 字段名
        /// </summary>
        public string ColCode
        {
            get { return _colCode; }
            set { _colCode = value; }
        }

        /// <summary>
        /// 列名
        /// </summary>
        public string ColName
        {
            get { return _colName; }
            set { _colName = value; }
        }

        /// <summary>
        /// 列是否显示
        /// </summary>
        public bool ColShow
        {
            get { return _colShow; }
            set { _colShow = value; }
        }

        /// <summary>
        /// 列宽度
        /// </summary>
        public int ColWidth
        {
            get { return _colWidth; }
            set { _colWidth = value; }
        }

        public SelGridColumn(string colCode, string colName)
        {
            this._colCode = colCode;
            this._colName = colName;
        }

        public SelGridColumn(string colCode, string colName, bool colShow)
        {
            this._colCode = colCode;
            this._colName = colName;
            this._colShow = colShow;
        }

        public SelGridColumn(string colCode, string colName, bool colShow, int colWidth)
        {
            this._colCode = colCode;
            this._colName = colName;
            this._colShow = colShow;
            this._colWidth = colWidth;
        }
    }
}